// default package
// Generated 28 Jul, 2014 8:04:07 PM by Hibernate Tools 3.4.0.CR1
package com.galaxy.bean;

import java.util.HashSet;
import java.util.Set;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;

/**
 * CatalogProductLinkType generated by hbm2java
 */
@Entity
@Table(name = "catalog_product_link_type", catalog = "magento")
public class CatalogProductLinkType implements java.io.Serializable {

	private static final long serialVersionUID = 121323L;

	private Short linkTypeId;
	private String code;
	private Set catalogProductLinkAttributes = new HashSet(0);
	private Set catalogProductLinks = new HashSet(0);

	public CatalogProductLinkType() {
	}

	public CatalogProductLinkType(String code) {
		this.code = code;
	}

	public CatalogProductLinkType(String code,
			Set catalogProductLinkAttributes, Set catalogProductLinks) {
		this.code = code;
		this.catalogProductLinkAttributes = catalogProductLinkAttributes;
		this.catalogProductLinks = catalogProductLinks;
	}

	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "link_type_id", unique = true, nullable = false)
	public Short getLinkTypeId() {
		return this.linkTypeId;
	}

	public void setLinkTypeId(Short linkTypeId) {
		this.linkTypeId = linkTypeId;
	}

	@Column(name = "code", nullable = false, length = 32)
	public String getCode() {
		return this.code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	@OneToMany(fetch = FetchType.LAZY, mappedBy = "catalogProductLinkType")
	public Set getCatalogProductLinkAttributes() {
		return this.catalogProductLinkAttributes;
	}

	public void setCatalogProductLinkAttributes(Set catalogProductLinkAttributes) {
		this.catalogProductLinkAttributes = catalogProductLinkAttributes;
	}

	@OneToMany(fetch = FetchType.LAZY, mappedBy = "catalogProductLinkType")
	public Set getCatalogProductLinks() {
		return this.catalogProductLinks;
	}

	public void setCatalogProductLinks(Set catalogProductLinks) {
		this.catalogProductLinks = catalogProductLinks;
	}

}
